let isDev = process.env.NODE_ENV === "development";

const UUID = isDev ? "uuid_key_dev" : "uuid_key";
const HAS_LOGIN =  "has_login_key";
const HAS_BIND_ROOM =  "has_bind_room_key";
const ACCESS_TOKEN =  "access_token_key";
const USER_INFO =  "user_info_obj";
export default {
	
 
 // 写入绑定房屋
 setHasBindRoom(val) {
   uni.setStorageSync(HAS_BIND_ROOM, val);
 },
 // 获取绑定房屋
 getHasBindRoom() {
   return uni.getStorageSync(HAS_BIND_ROOM);
 },
  
 
  // 写入用户信息
  setUserInfo(val) {
    uni.setStorageSync(USER_INFO, val);
  },
  // 获取用户信息
  getUserInfo() {
    return uni.getStorageSync(USER_INFO);
  },
 
  // 写入登录
  setHasLogin(val) {
    uni.setStorageSync(HAS_LOGIN, val);
  },
  // 获取是否登录
  getHasLogin() {
    return uni.getStorageSync(HAS_LOGIN);
  },
  setBindRoom(val) {
    uni.setStorageSync(HAS_BIND_ROOM, val);
  },
  // 获取是否登录
  getBindRoom() {
    return uni.getStorageSync(HAS_BIND_ROOM);
  },
  
  // 写入accessToken
  setAccessToken(val) {
    uni.setStorageSync(ACCESS_TOKEN, val);
  },
  // 获取accessToken
  getAccessToken() {
    return uni.getStorageSync(ACCESS_TOKEN);
  },
  
  
};
